<?php

require_once("core/functions.php");

if($_SERVER["REQUEST_METHOD"]=="GET")
{
	if(!isset($_GET["activationKey"]) && !isset($_GET["personId"]))
	{
		core::redirect("vwall.php");
	}
	else
	{
		$activationKey = core::sanitize($_GET["activationKey"]);
		$personId = core::sanitize($_GET["personId"]);

		if(core::tryActivating($personId,$activationKey))
		{
			Core::redirect("index.php");
		}
		else
		{
			echo "Activation Failed!";
            
		}

	}
}

?>